import { post, get } from "utils/request.js";

// 自定义api
export function custom(params) {
  const { url, method, data } = params;
  if (method === "get") {
    return get(url, data);
  }
  return post(url, data);
}
/**
 * 七牛云token
 */
export function UploadToken(data){
  return post("/uploadIToken/", data);
}
// 富文本-图片上传
export function UploadEditor(data){
  return post("/upload/", data);
}


// 部门
export function departAdd(data) {
  return post("/department/add/", data);
}
//@params: name pageNumber pageSize
export function departList(data) {
  return post("department/list/", data);
}
//@params: id  String
export function departDelete(data) {
  return post("/department/delete/", data);
}
// @params id status
export function departStatus(data) {
  return post("/department/status/", data);
}
// @params id status
export function departDetailed(data) {
  return post("/department/detailed/", data);
}
// 职位 